package com.msb.mall.mallsearch.vo;

import com.msb.common.dto.es.SkuESModel;
import lombok.Data;

import java.util.List;

/**
 * @Author zhangjiajun
 * @Email zhangjiajun@hydsoft.com
 * @Description   封装检索后的响应信息
 * @Date 2025/7/29 9:36
 */
@Data
public class SearchResult {

    private List<SkuESModel> products;   //满足条件的商品信息


    //分页信息
    private Integer pageNum;
    //总的记录数
    private Long total;
    //总页数
    private Integer totalPages;

    //需要分页显示的页码
    private List<Integer> navs;


    //当前查询的所有的商品涉及到的所有的商品信息
    private List<BrandVO> brands;

    //当前查询的商品涉及到的所有属性信息
    private List<AttrVO> attrs;

    //当前查询的所有商品涉及到的类别信息
    private List<CatalogVO> catalogs;

    @Data
    public static class CatalogVO{
        private Long catalogId;
        private String catalogName;
    }

    //品牌的相关信息
    @Data
    public static class BrandVO{
        private Long brandId;
        private String brandName;
        private String brandImg;

    }


    @Data
    public static class AttrVO {
        private Long attrId;
        private String attrName;
        private List<String> attrValues;
    }


}
